#!/usr/bin/env python

from pprint import pprint

from veles.schema import nodeid
from veles.scli import client
from veles.util import helpers

parser = helpers.get_client_argparse()
parser.add_argument('id', help='hex-encoded id of object')
args = parser.parse_args()

client = client.create_client(args.server_url)
obj = nodeid.NodeID.from_hex(args.id)
for x in client.get_sub(obj):
    pprint(x)
